from manim import *
from numpy import flip, insert

LV,QL,QH,JH='#75cfb8','#bbdfc8','#f0e5d8','#ffc478'

class p1(MovingCameraScene):
    def construct(self):
        # self.add(NumberPlane().set_color(GRAY))
        # self.camera.frame.scale(0.5)
        li=[[5,2,0],[4,-2,0],[1,-3,0],[-4,-1,0],[-2,3,0]]
        for i in range(len(li)):
            side=Line(li[i-1],li[i])
            if i ==len(li)-1:
                li.append(li[0])
            self.add(side,
                Angle(Line(li[i],li[i-1]),Line(li[i],li[i+1])),
                side.copy().scale(1.3),
            )
        self.add(
            MathTex('1').next_to(li[1]).shift(UL*0.5),
            MathTex('2').next_to(li[2]).shift(UP*0.5+LEFT*0.2),
            MathTex('3').next_to(li[3]).shift(RIGHT*0.3+UP*0.2),
            MathTex('4').next_to(li[4]).shift(DOWN*0.5),
            MathTex('\cdots').next_to(li[5]).shift(LEFT*0.8+DOWN*0.2),
        )
        self.wait()